<!DOCTYPE html>
<html>
<head>
    {include file='public/meta'/}
</head>
<body>

{include file='public/header'/}
<!------------------导航-------------------------->
<section>
    {include file='public/left'/}
    <!--------------------------主要内容区域------------------------------------->
    <div class="content">
        <div class="page-heading  mgr15 mgl15">
            <ul class="breadcrumb">
                <li>
                    当前位置是&nbsp;:&nbsp;系统管理
                </li>
                <li class="active" style="color: #02b87f;"> 类别管理</li>
            </ul>
        </div>
        <div class="panel mgr15 mgl15" style="position: relative;">
            <div class="panel-heading addCharts" style="background:#ededed;">添加类别</div>
            <div class="col-sm-12 text-right mgb10" style="position:absolute;right:20px;top:4px;">
                <button data-toggle="modal" data-target="#myModal" type="button" name="Cashier" method="post" action="" class="btn btn-info">添加类别</button>
            </div>
            <div class="panel-body">
            <table class="table table-bordered">
                <thead>
                <tr>
                    <th>#</th>
                    <th>行业级别</th>
                    <th>行业名称</th>
                    <th>父级行业</th>
                    <th>操作</th>
                </tr>
                </thead>
                <tbody>

                </tbody>
            </table>
            </div>
        </div>
        {include file='public/footer'/}
    </div>
</section>
<!-- 添加类别模态框（Modal） -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">
                    &times;
                </button>
                <h4 class="modal-title" id="myModalLabel">
                    添加类别
                </h4>
            </div>
            <div class="modal-body">
                <div class="panel-body">
                    <form class="form-horizontal adminex-form" action="" method="post" id="sysuser"
                          enctype="multipart/form-data">
                        <div class="form-group" id="levelst">
                            <label class="col-sm-2 col-sm-2 control-label">一级类别:</label>
                            <div class="col-lg-10">
                                <select class="form-control input-sm m-bot15 ipt4" name="level" id="leveltop" onchange="showqx()">
                                    <option value="">选择一级类别</option>
                                    <option value="0">新增一级类别</option>

                                </select>
                            </div>
                        </div>
                        <div class="form-group" id="ferror2" style="display: none;">
                            <label class="col-sm-2 col-sm-2 control-label" id="levellb">二级类别:</label>
                            <div class="col-sm-10">
                                <input type="text" id="level" name="password" class="form-control ipt4">
                                <div id="error2" class="error"></div>
                            </div>
                        </div>
                        <!--<div class="text-center">
                                    <button type="button" onclick="addform()" class="btn btn-primary">添加类别</button>
                                </div>-->
                    </form>
                </div>
            </div>
            <div class="modal-footer" style="border-top:0;">
                <button type="button" class="btn btn-default" data-dismiss="modal">关闭
                </button>
                <button type="button" class="btn btn-primary" onclick="addform()">
                    提交
                </button>
            </div>
        </div><!-- /.modal-content -->
    </div><!-- /.modal -->
</div>
<!--修改模态框-->
<div class="modal fade" id="myModal2" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"
     aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close cateclose" data-dismiss="modal" aria-hidden="true">
                    &times;
                </button>
                <h4 class="modal-title" id="myModalLabel2">
                    级别维护
                </h4>
            </div>
            <div class="modal-body" id="lbinfo">

            </div>
            <div class="modal-footer" style="border-top: 0;">
                <button type="button" class="btn btn-default" data-dismiss="modal">关闭
                </button>
                <button type="button" class="btn btn-primary"  onclick="xgform()">
                    提交
                </button>
            </div>
        </div><!-- /.modal-content -->
    </div><!-- /.modal -->
</div>



<script>
    function showqx() {
        var va = $('#leveltop').val();

        if (va == '0') {

            $('#levellb').html('一级类别');
        } else {
            $('#levellb').html('二级类别');
        }
        $('#ferror2').show();

    }
    ;




</script>
</body>
</html>
